import http from '../../utils/request'

export async function getBankQuestionSum( ) {
  return http.request({
    url: '/teacher/getBankHaveQuestionSumByType?pageNo=1&pageSize=9999',
    method: 'get',
  })
}

export async function getFetchQuestions(questionType,questionBank,questionContent,pageNo,pageSize) {
  return http.request({
    url: `/teacher/getQuestion?questionType=${questionType}&questionBank=${questionBank}&questionContent=${questionContent}&pageNo=${pageNo}&pageSize=${pageSize}`,
    method: 'get',
  })
}

export async function addExamByBank(data:any) {
  return http.request({
    url: '/teacher/addExamByBank',
    method: 'post',
    data
  })
}

export async function addExamByQuestionList(data:any) {
    return http.request({
      url: '/teacher/addExamByQuestionList',
      method: 'post',
      data
    })
  }